// File generated from our OpenAPI spec by Stainless.

package com.metest.api.models.pet

import org.assertj.core.api.Assertions.assertThat
import org.junit.jupiter.api.Test

internal class PetUpdateWithFormParamsTest {

    @Test
    fun create() {
        PetUpdateWithFormParams.builder().petId(0L).name("name").status("status").build()
    }

    @Test
    fun pathParams() {
        val params = PetUpdateWithFormParams.builder().petId(0L).build()

        assertThat(params._pathParam(0)).isEqualTo("0")
        // out-of-bound path param
        assertThat(params._pathParam(1)).isEqualTo("")
    }

    @Test
    fun body() {
        val params =
            PetUpdateWithFormParams.builder().petId(0L).name("name").status("status").build()

        val body = params._body()

        assertThat(body.name()).contains("name")
        assertThat(body.status()).contains("status")
    }

    @Test
    fun bodyWithoutOptionalFields() {
        val params = PetUpdateWithFormParams.builder().petId(0L).build()

        val body = params._body()
    }
}
